<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .rocket {
            width: 300px;
            position: absolute;
            left: 300px;
            top: 200px;
            animation: fly 0.5s linear infinite alternate;
        }

        /* 火箭飞行动画 */
        @keyframes fly {
            0% {
                transform: translate(-30px, -30px);
            }

            100% {
                transform: translate(30px, 30px);
            }
        }

        .line {
            width: 1px;
            height: 160px;
            position: absolute;
            background-color: blue;
        }

        .pos1 {
            top: 200px;
            left: 400px;
        }

        .pos2 {
            top: 240px;
            left: 450px;
        }

        .pos3 {
            top: 290px;
            left: 500px;
        }

        .pos4 {
            top: 320px;
            left: 550px;
        }

        .animation-cloud {
            animation: cloud 1s linear var(--delay) infinite backwards;

        }

        /* 流云动画 */

        @keyframes cloud {
            0% {
                opacity: 0;
                /* 先旋转后位移 */
                transform: rotate(55deg) translateY(-200px);
            }

            70% {
                opacity: 1;
            }

            100% {
                opacity: 0;
                transform: rotate(55deg) translateY(200px);

            }
        }
    </style>
</head>

<body>
    <img src="./images/rocket.png" class="rocket">
    <div class="line pos1 animation-cloud" style="--delay:0s"></div>
    <div class="line pos2 animation-cloud" style="--delay:0.4s"></div>
    <div class="line pos3 animation-cloud" style="--delay:0.6s"></div>
    <div class="line pos4 animation-cloud" style="--delay:0.8s"></div>
</body>

</html>
